/*
 * system.h
 *
 * define some system APIs
 *
 * Copyright (C) 2024 Sinh Micro, Inc.
 * Subject to the GNU Public License, version 2.
 *
 * Author: lixiang<lixiang@sinhmicro.com>
 * 
 * Encoding format: GB2312
 * Version: v1.2.2
 * Date: 2024-11-05
 */

#ifndef __SYSTEM_H__
#define __SYSTEM_H__

#include "hal-config.h"
#include "hal-regs.h"

#include "types.h"
/*
 * please realize these APIs or Macro as below:
 * 1. the frequency of clock source : HIRC, LORC, PLLCLK(for ss887x)...
 *    SYS_LORC_FREQ
 *    SYS_HIRC_FREQ
 *    SYS_PLLCLK_FREQ
 *
 * 2. the frequency of system clock before frequency division : SYS_PRE_SCLK_FREQ
 *    SYS_PRE_SCLK_FREQ
 *
 * 3. the frequency of system clock after frequency division(SYS_PRE_SCLK_FREQ / CONFIG_SYS_SCLK_DIV) : SYS_SCLK_FREQ
 *    SYS_SCLK_FREQ
 *
 * 4. enable/disable interrupt enable :
 *    SYS_IRQ_ENABLE()
 *    SYS_IRQ_DISABLE()
 *
 * 5. the system enter sleep mode :
 *    SYS_ENTER_SLEEP()
 *
 * 6. reset the wdog :
 *    SYS_WDOG_KEEP_ALIVE()
 *   
 */  

#include "system/system-ss805x.h"		

/*
 * this function is used to initialize the system driver.
 *
 * @param[in]  None
 */
void sys_init(void);


#endif

